package hibernate.method.interfaces;

import java.util.List;

import hibernate.model.GamesRate;
import hibernate.model.LocalRate;

import org.hibernate.Session;
import org.hibernate.SessionFactory;

public interface RateMethodsInterface {
	
	public void addGameRate(SessionFactory sessionFactory, Session session, int user_id, int game_id, int rate);
	
	public void addLocalRate(SessionFactory sessionFactory, Session session, int user_id, int local_id, int rate);
	
	public void editGameRate(SessionFactory sessionFactory, Session session, GamesRate r, int rate);
	
	public void editLocalRate(SessionFactory sessionFactory, Session session, LocalRate r, int rate);
	
	public List<GamesRate> findGameRateByUserGame(SessionFactory sessionFactory, Session session, int user_id, int game_id);
	
	public List <GamesRate> findGameRateByUser(SessionFactory sessionFactory, Session session, int user_id);
	
	public List<LocalRate> findLocalRateByUserGame(SessionFactory sessionFactory, Session session, int user_id, int local_id);
	
	public GamesRate idToGameRate(SessionFactory sessionFactory, Session session, int gameRate_id);
	
	public LocalRate idToLocalRate(SessionFactory sessionFactory, Session session, int localRate_id);
	
	public String returnAverageRateByGame(SessionFactory sessionFactory, Session session, int game_id);
	
	public String returnAverageRateByLocal(SessionFactory sessionFactory, Session session, int local_id);
	

}
